package com.geek.video.exception;

import com.geek.video.enums.ResponseEnum;

/**
 * 自定义全局异常
 *
 * @author qinxh
 */
public class GlobalException extends RuntimeException {

    private static final long serialVersionUID = 1L;

    private ResponseEnum responseEnum;

    public GlobalException(ResponseEnum responseEnum) {
        super(responseEnum.getMessage());
        this.responseEnum = responseEnum;
    }

    public GlobalException(String message) {

        super(message);
    }

    public ResponseEnum getmessage() {

        return responseEnum;
    }
}